package router

import (
	"longmen/server/internal/api"

	"github.com/labstack/echo/v4"
)

func initSportsRoute(group *echo.Group, base api.Controller, authFunc echo.MiddlewareFunc) {
	group.POST("/sport/getHotMatchCards", base.GetHotMatchCards4Crawler) //首页赛事信息滚动卡 爬虫数据

	// 世界杯
	group.POST("/sport/world_cup_group_match", base.WCGMatch)
	group.POST("/sport/world_cup_team_point", base.WCTeamPoint)
	group.POST("/sport/world_cup_team_rank", base.WCTeamRank)
	group.POST("/sport/world_cup_game_team", base.WCGameTeam)
	group.POST("/sport/world_cup_game_order", base.WCGameOrder)
	group.POST("/sport/world_cup_game_order_list", base.WCGameOrderList)

	//首页推荐的赛事
	group.POST("/matches/suggested", base.GetRecommendMatches4Crawler) //首页推荐的赛事 爬虫数据

	//赛事信息
	group.POST("/match/getRecommendMatches4Crawler", base.GetRecommendMatches4Crawler)         //首页推荐的赛事 爬虫数据
	group.POST("/match/getHotMatchCards4Crawler", base.GetHotMatchCards4Crawler)               //首页赛事信息滚动卡 爬虫数据
	group.POST("/match/getCompetation4Crawler", base.GetCompetation4Crawler)                   //获取联赛信息 爬虫数据
	group.POST("/match/getMatch4Crawler", base.GetMatch4Crawler)                               //获取赛事信息 爬虫数据
	group.POST("/match/reserveMatch4Crawler", base.ReserveMatch4Crawler, authFunc)             //用户预约赛事 爬虫数据
	group.POST("/match/getReservedMatch4Crawler", base.GetReservedMatch4Crawler, authFunc)     //获取用户预约的赛事 爬虫数据
	group.POST("/match/cancelReserveMatch4Crawler", base.CancelReserveMatch4Crawler, authFunc) //用户取消预约赛事 爬虫数据
	group.POST("/match/getSportMatch", base.GetSportMatch)                                     //获取当前天赛事根据联赛名称(移动端)
	group.POST("/match/getSportMatchComp", base.GetSportMatchComp)                             //  获取当前天赛事(移动端)
	group.POST("/match/getCompMenuList", base.GetCompMenuList)                                 //  赛程筛选菜单(移动端)
	group.POST("/match/getMatchList", base.GetMatchList, authFunc)                             //  赛程列表(移动端)
	group.POST("/match/getMatchScoreList", base.GetMatchScoreList)                             //  赛事比分
	group.POST("/match/favoriteMatch", base.FavoriteMatch, authFunc)                           //  收藏赛事/取消收藏(移动端)
	group.POST("/match/countUserFavorite", base.CountUserFavorite, authFunc)                   //  会员收藏赛事总条数(移动端)
	group.POST("/match/getMatchById", base.GetMatchById)                                       //  根据赛事ID,获取赛事信息
	//groupMatch.POST("/getSign", base.GetSign) //  生成签名字符串

	//指数
	// 篮球初盘
	group.POST("/odds/basketball_initial", base.GetBasketBallInitialOdds)
	// 篮球历史
	group.POST("/odds/basketball_history", base.GetBasketBallOddsHistory)
	// 足球初盘
	group.POST("/odds/football_initial", base.GetFootballInitialOdds)
	// 足球历史
	group.POST("/odds/football_history", base.GetFootballOddsHistory)

	///matchLive
	group.POST("/matchLive/text", base.GetMatchText)

	group.POST("/match/getMatchLiveUrl", base.MatchLiveUrl) //赛事直播链接

	//55直播
	group.POST("/match/get55MatchList", base.Get55MatchList)
	group.POST("/match/get55HotLeague", base.Get55HotLeague)

	group.POST("/match/get55MatchList2", base.GetSeoMatchList) //接口不加密

	// 赛事积分榜
	group.POST("/event/point", base.Compint)

	// 赛事战队信息
	group.POST("/lineup/getLineupByMatch", base.GetLineupByMatch)

	//简化阵容信息接口
	group.POST("/sport/lineup", base.Lineup)
	group.POST("/sport/score", base.Score)

	// 积分榜详情
	group.POST("/sport/point_detail", base.PointTeamDetail, authFunc)
}
